package jp.java.test1.pkg10_19.test19;

enum Member {
	SCOTT {
		String hello() {
			return "scott hello";
		}
	},
	
	TEST {
		public String hello() {
			return "test hello";
		}
	},;
	
	String hello() {
		return "test";
	};
//	abstract String hello();
}

public class Main {

	public static void main(String[] args) {
		String [] members = {"Scott", "Test"};
		for(String name : members) {
			Member member = null;
			try {
				member = Member.valueOf(name.toUpperCase());
				System.out.println(member.hello());
			} catch (Exception e) {
				// TODO 自動生成された catch ブロック
				e.printStackTrace();
			}
		}

	}

}
